home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 2 / Apprentice-Release2.iso / Tools / Languages / GCC 1.37.1r14 / BSD #includes / sys / sys⁄systm.h < prev    next >
Encoding:
Text File  |  1992-09-04  |  4.6 KB  |  120 lines  |  [TEXT/UNIX]

  1. /*-
  2.  * Copyright (c) 1982, 1988, 1991 The Regents of the University of California.
  3.  * All rights reserved.
  4.  *
  5.  * Redistribution and use in source and binary forms, with or without
  6.  * modification, are permitted provided that the following conditions
  7.  * are met:
  8.  * 1. Redistributions of source code must retain the above copyright
  9.  *    notice, this list of conditions and the following disclaimer.
  10.  * 2. Redistributions in binary form must reproduce the above copyright
  11.  *    notice, this list of conditions and the following disclaimer in the
  12.  *    documentation and/or other materials provided with the distribution.
  13.  * 3. All advertising materials mentioning features or use of this software
  14.  *    must display the following acknowledgement:
  15.  *    This product includes software developed by the University of
  16.  *    California, Berkeley and its contributors.
  17.  * 4. Neither the name of the University nor the names of its contributors
  18.  *    may be used to endorse or promote products derived from this software
  19.  *    without specific prior written permission.
  20.  *
  21.  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  22.  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  23.  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  24.  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  25.  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  26.  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  27.  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  28.  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  29.  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  30.  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  31.  * SUCH DAMAGE.
  32.  *
  33.  *    @(#)systm.h    7.17 (Berkeley) 5/25/91
  34.  */
  35.  
  36. extern char *panicstr;        /* panic message */
  37. extern char version[];        /* system version */
  38. extern char copyright[];    /* system copyright */
  39.  
  40. extern int nblkdev;        /* number of entries in bdevsw */
  41. extern int nchrdev;        /* number of entries in cdevsw */
  42. extern int nswdev;        /* number of swap devices */
  43. extern int nswap;        /* size of swap space */
  44.  
  45. extern int selwait;        /* select timeout address */
  46.  
  47. extern u_char curpri;        /* priority of current process */
  48.  
  49. extern int maxmem;        /* max memory per process */
  50. extern int physmem;        /* physical memory */
  51.  
  52. extern dev_t dumpdev;        /* dump device */
  53. extern long dumplo;        /* offset into dumpdev */
  54.  
  55. extern dev_t rootdev;        /* root device */
  56. extern struct vnode *rootvp;    /* vnode equivalent to above */
  57.  
  58. extern dev_t swapdev;        /* swapping device */
  59. extern struct vnode *swapdev_vp;/* vnode equivalent to above */
  60.  
  61. extern struct sysent {        /* system call table */
  62.     int    sy_narg;    /* number of arguments */
  63.     int    (*sy_call)();    /* implementing function */
  64. } sysent[];
  65.  
  66. extern int boothowto;        /* reboot flags, from console subsystem */
  67. #ifdef    KADB
  68. extern char *bootesym;        /* end of symbol info from boot */
  69. #endif
  70.  
  71. /* casts to keep lint happy */
  72. #define    insque(q,p)    _insque((caddr_t)q,(caddr_t)p)
  73. #define    remque(q)    _remque((caddr_t)q)
  74.  
  75. /*
  76.  * General function declarations.
  77.  */
  78. int    nullop __P((void));
  79. int    enodev __P((void));
  80. int    enoioctl __P((void));
  81. int    enxio __P((void));
  82. int    eopnotsupp __P((void));
  83. int    seltrue __P((dev_t dev, int which, struct proc *p));
  84.  
  85. void    panic __P((char *));
  86. void    tablefull __P((char *));
  87. void    addlog __P((const char *, ...));
  88. void    log __P((int, const char *, ...));
  89. void    printf __P((const char *, ...));
  90. int    sprintf __P((char *buf, const char *, ...));
  91. void    ttyprintf __P((struct tty *, const char *, ...));
  92.  
  93. void    bcopy __P((void *from, void *to, u_int len));
  94. void    ovbcopy __P((void *from, void *to, u_int len));
  95. void    bzero __P((void *buf, u_int len));
  96. int    bcmp __P((void *str1, void *str2, u_int len));
  97. int    strlen __P((char *string));
  98.  
  99. int    copystr __P((void *kfaddr, void *kdaddr, u_int len, u_int *done));
  100. int    copyinstr __P((void *udaddr, void *kaddr, u_int len, u_int *done));
  101. int    copyoutstr __P((void *kaddr, void *udaddr, u_int len, u_int *done));
  102. int    copyin __P((void *udaddr, void *kaddr, u_int len));
  103. int    copyout __P((void *kaddr, void *udaddr, u_int len));
  104.  
  105. int    fubyte __P((void *base));
  106. #ifdef notdef
  107. int    fuibyte __P((void *base));
  108. #endif
  109. int    subyte __P((void *base, int byte));
  110. int    suibyte __P((void *base, int byte));
  111. int    fuword __P((void *base));
  112. int    fuiword __P((void *base));
  113. int    suword __P((void *base, int word));
  114. int    suiword __P((void *base, int word));
  115.  
  116. int    scanc __P((unsigned size, u_char *cp, u_char *table, int mask));
  117. int    skpc __P((int mask, int size, char *cp));
  118. int    locc __P((int mask, char *cp, unsigned size));
  119. int    ffs __P((long value));
  120.